package com.ws.operator;
/*
练习，随意一个整数，打印出它的个位数，十位数，百位数
 */
public class ArithmeticExercise {

    public static void main(String[] args) {
        int number = 157;

        int singleDigit = number % 10;
        System.out.println("个位数是：" + singleDigit);
        int tenDigits = number / 10 % 10;
        System.out.println("十位数是：" + tenDigits);
        int hundreds = number / 100;
        System.out.println("百位数是：" + hundreds);
    }
}
